import tkinter as tk
from button_component import ButtonComponent
from form_component import FormComponent

# 按钮组件示例
def button_example():
    root = tk.Tk()
    def on_click():
        print('按钮被点击!')
    button = ButtonComponent(root, '点击我', on_click)
    root.mainloop()

# 表单组件示例
def form_example():
    root = tk.Tk()
    form = FormComponent(root, ['姓名', '邮箱', '密码', '视频路径'])
    root.mainloop()

if __name__ == '__main__':
    # 运行按钮示例
    button_example()
    # 运行表单示例
    form_example()